home *** CD-ROM | disk | FTP | other *** search
/ C & C++ Multimedia Cyber Classroom / C and C++ Multimedia Cyber Classroom (Prentice Hall) (1998).iso / src / fig09_11.jar / Ch09 / Fig09_11 / Base1.h next >
C/C++ Source or Header  |  1997-08-25  |  302b  |  16 lines

  1. // Fig. 9.11: base1.h
  2. // Definition of class Base1
  3. #ifndef BASE1_H
  4. #define BASE1_H
  5.  
  6. class Base1 {
  7. public:
  8.    Base1( int x ) { value = x; }
  9.    int getData() const { return value; }
  10. protected:      // accessible to derived classes
  11.    int value;   // inherited by derived class
  12. };
  13.  
  14. #endif
  15.  
  16.